import 'dart:ui';

import 'package:flutter/material.dart';
import 'package:fluttertoast/fluttertoast.dart';

class ToastUtils {
  static show(msg) {
    Fluttertoast.cancel();
    Fluttertoast.showToast(
        msg: msg,
        toastLength: Toast.LENGTH_SHORT,
        gravity: ToastGravity.CENTER,
        //显示时长(ios & web)
        timeInSecForIosWeb: 1,
        backgroundColor: const Color(0xff606060),
        textColor: Colors.white,
        fontSize: 14.0);
  }
}
